<?php
session_start();
include_once ("../php/connect_mysql.php");
//点击之后传了个id过来
//这边php文件通过GET接受传过来的id
$cid = $_GET['cid'];
$new_comment = htmlspecialchars($_GET['desc']);
$upd_sql = "update comment_info set comment='$new_comment' where cid=$cid";
$conn->query($upd_sql);
header("Location:../index.php");